-
Notifications
You must be signed in to change notification settings - Fork 3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[DML] Register DML operators for opset 19 #16939
Conversation
onnxruntime/core/providers/dml/DmlExecutionProvider/src/Operators/DmlOperatorElementWise.cpp
Outdated
Show resolved
Hide resolved
static const int sc_sinceVer_Constant = 19; | ||
static const int sc_sinceVer_Equal = 19; | ||
static const int sc_sinceVer_Identity = 19; | ||
static const int sc_sinceVer_QuantizeLinear = 19; |
Check warning
Code scanning / PREfast
The const variable 'OperatorHelper::OnnxOperatorSet19::sc_sinceVer_QuantizeLinear' can be computed at compile-time. Consider using constexpr (con.5).
static const int sc_sinceVer_Equal = 19; | ||
static const int sc_sinceVer_Identity = 19; | ||
static const int sc_sinceVer_QuantizeLinear = 19; | ||
static const int sc_sinceVer_DequantizeLinear = 19; |
Check warning
Code scanning / PREfast
The const variable 'OperatorHelper::OnnxOperatorSet19::sc_sinceVer_DequantizeLinear' can be computed at compile-time. Consider using constexpr (con.5).
namespace OnnxOperatorSet19 | ||
{ | ||
static const int sc_sinceVer_Cast = 19; | ||
static const int sc_sinceVer_CastLike = 19; |
Check warning
Code scanning / PREfast
The const variable 'OperatorHelper::OnnxOperatorSet19::sc_sinceVer_CastLike' can be computed at compile-time. Consider using constexpr (con.5).
static const int sc_sinceVer_Identity = 19; | ||
static const int sc_sinceVer_QuantizeLinear = 19; | ||
static const int sc_sinceVer_DequantizeLinear = 19; | ||
static const int sc_sinceVer_Reshape = 19; |
Check warning
Code scanning / PREfast
The const variable 'OperatorHelper::OnnxOperatorSet19::sc_sinceVer_Reshape' can be computed at compile-time. Consider using constexpr (con.5).
{ | ||
static const int sc_sinceVer_Cast = 19; | ||
static const int sc_sinceVer_CastLike = 19; | ||
static const int sc_sinceVer_Constant = 19; |
Check warning
Code scanning / PREfast
The const variable 'OperatorHelper::OnnxOperatorSet19::sc_sinceVer_Constant' can be computed at compile-time. Consider using constexpr (con.5).
static const int sc_sinceVer_Cast = 19; | ||
static const int sc_sinceVer_CastLike = 19; | ||
static const int sc_sinceVer_Constant = 19; | ||
static const int sc_sinceVer_Equal = 19; |
Check warning
Code scanning / PREfast
The const variable 'OperatorHelper::OnnxOperatorSet19::sc_sinceVer_Equal' can be computed at compile-time. Consider using constexpr (con.5).
static const int sc_sinceVer_CastLike = 19; | ||
static const int sc_sinceVer_Constant = 19; | ||
static const int sc_sinceVer_Equal = 19; | ||
static const int sc_sinceVer_Identity = 19; |
Check warning
Code scanning / PREfast
The const variable 'OperatorHelper::OnnxOperatorSet19::sc_sinceVer_Identity' can be computed at compile-time. Consider using constexpr (con.5).
static const int sc_sinceVer_QuantizeLinear = 19; | ||
static const int sc_sinceVer_DequantizeLinear = 19; | ||
static const int sc_sinceVer_Reshape = 19; | ||
static const int sc_sinceVer_Shape = 19; |
Check warning
Code scanning / PREfast
The const variable 'OperatorHelper::OnnxOperatorSet19::sc_sinceVer_Shape' can be computed at compile-time. Consider using constexpr (con.5).
static const int sc_sinceVer_DequantizeLinear = 19; | ||
static const int sc_sinceVer_Reshape = 19; | ||
static const int sc_sinceVer_Shape = 19; | ||
static const int sc_sinceVer_Size = 19; |
Check warning
Code scanning / PREfast
The const variable 'OperatorHelper::OnnxOperatorSet19::sc_sinceVer_Size' can be computed at compile-time. Consider using constexpr (con.5).
onnxruntime/core/providers/dml/DmlExecutionProvider/src/Operators/DmlOperatorElementWise.cpp
Show resolved
Hide resolved
This comment was marked as outdated.
This comment was marked as outdated.
onnxruntime/core/providers/dml/DmlExecutionProvider/src/Operators/DmlOperatorElementWise.cpp
Outdated
Show resolved
Hide resolved
onnxruntime/core/providers/dml/DmlExecutionProvider/src/Operators/DmlOperatorElementWise.cpp
Outdated
Show resolved
Hide resolved
onnxruntime/core/providers/dml/DmlExecutionProvider/src/Operators/DmlOperatorElementWise.cpp
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Some comments ⏳. Glad you figured it out, forming the graph and fill value constant 👍.
onnxruntime/core/providers/dml/DmlExecutionProvider/src/Operators/DmlOperatorElementWise.cpp
Outdated
Show resolved
Hide resolved
const DML_OPERATOR_DESC* opDescs[] = {&opDesc1, &opDesc2}; | ||
operatorGraphDesc.nodesAsOpDesc = std::data(opDescs); | ||
|
||
const uint32_t fillValueNodeIndex = 0; |
Check warning
Code scanning / PREfast
The const variable 'fillValueNodeIndex' can be computed at compile-time. Consider using constexpr (con.5).
operatorGraphDesc.nodesAsOpDesc = std::data(opDescs); | ||
|
||
const uint32_t fillValueNodeIndex = 0; | ||
const uint32_t dequantizeNodeIndex = 1; |
Check warning
Code scanning / PREfast
The const variable 'dequantizeNodeIndex' can be computed at compile-time. Consider using constexpr (con.5).
const DML_OPERATOR_DESC* opDescs[] = {&opDesc1, &opDesc2}; | ||
operatorGraphDesc.nodesAsOpDesc = std::data(opDescs); | ||
|
||
const uint32_t fillValueNodeIndex = 0; |
Check warning
Code scanning / PREfast
The const variable 'fillValueNodeIndex' can be computed at compile-time. Consider using constexpr (con.5).
onnxruntime/core/providers/dml/DmlExecutionProvider/src/Operators/DmlOperatorElementWise.cpp
Outdated
Show resolved
Hide resolved
onnxruntime/core/providers/dml/DmlExecutionProvider/src/Operators/DmlOperatorElementWise.cpp
Outdated
Show resolved
Hide resolved
onnxruntime/core/providers/dml/DmlExecutionProvider/src/Operators/DmlOperatorElementWise.cpp
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Some comments. Next round should be good.
onnxruntime/core/providers/dml/DmlExecutionProvider/src/Operators/DmlOperatorElementWise.cpp
Outdated
Show resolved
Hide resolved
onnxruntime/core/providers/dml/DmlExecutionProvider/src/Operators/DmlOperatorElementWise.cpp
Outdated
Show resolved
Hide resolved
…ml-19-registration and remove required zeropointtensor
onnxruntime/core/providers/dml/DmlExecutionProvider/src/Operators/DmlOperatorElementWise.cpp
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Description
Register DML operators for opset 19.
Motivation and Context